package com.zf.yichat.utils.HJpay.com.sdk.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.zf.yichat.utils.HJpay.com.sdk.constants.CommonConst;

/**
 * 商户请求的VO
 */
public class Request {
    private String method;
    private String version;
    @JSONField(jsonDirect = true)
    private String data;
    private String rand_str;
    private String sign_type;
    private String mch_id;
    private String sign;
    private String aes_key;

    public String getMethod() {
        return method;
    }

    public void setMethod(String method) {
        this.method = method;
    }

    public String getVersion() {
        return version;
    }

    public void setVersion(String version) {
        this.version = version;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }

    public String getRand_str() {
        return rand_str;
    }

    public void setRand_str(String rand_str) {
        this.rand_str = rand_str;
    }

    public String getSign_type() {
        return sign_type;
    }

    public void setSign_type(String sign_type) {
        this.sign_type = sign_type;
    }

    public String getMch_id() {
        return mch_id;
    }

    public void setMch_id(String mch_id) {
        this.mch_id = mch_id;
    }

    public String getSign() {
        return sign;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }

    public String getAes_key() {
        return aes_key;
    }

    public void setAes_key(String aes_key) {
        this.aes_key = aes_key;
    }

    /**
     * 拼接aes_key
     * @param aes_key
     * @param iv
     */
    public void joinAesKey(String aes_key, String iv){
        this.aes_key = aes_key + CommonConst.AES_KEY_SEPARATOR + iv;
    }
}
